<!DOCTYPE html>
<html lang="zh-cn">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<meta http-equiv="X-UA-Compatible" content="IE=edge">
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
		<meta name="renderer" content="webkit">
		<title>家长交流</title>
		<import type='css' file="admin.pintuer4.css.pintuer" />
		<import type='css' file="admin.pintuer4.css.admin" />
		<link type="image/x-icon" href="http://www.pintuer.com/favicon.ico" rel="shortcut icon" />
		<link href="http://www.pintuer.com/favicon.ico" rel="bookmark icon" />
	</head>

	<body>
		<include file="Public:header" />
	<!--内容-->
	<div class="layout">
		<div class="admin">
		<div class="padding border-bottom">
			<a class="button button-small border-green" href="{:U('Article/article_add')}">添加文章</a>
			<a class="button button-small border-green"  {$_GET['c_id']==null?'style="background:#5D8;color: #FFF"':''} href="{:U('ArticleComm/article_comm')}">全部</a>
			<a class="button button-small border-green" {$_GET['c_id']==4?'style="background:#5D8;color: #FFF"':''} href="{:U('ArticleComm/article_comm')}?c_id=4">初一专区</a>
			<a class="button button-small border-green" {$_GET['c_id']==5?'style="background:#5D8;color: #FFF"':''} href="{:U('ArticleComm/article_comm')}?c_id=5">初二专区</a>
			<a class="button button-small border-green" {$_GET['c_id']==6?'style="background:#5D8;color: #FFF"':''} href="{:U('ArticleComm/article_comm')}?c_id=6">初三专区</a>
			<a style="float: right;margin-left: 20px;" id="search" class="button button-small border-green" href="javascript:;">搜索</a>
			<input class="input input-small" style="width: 200px;float: right;" type="text" id="search_word" name="search_word" value="{$_GET['search_word']}"/>
	     </div>
		<form method="post">
		<input type="hidden" value="{$_GET['c_id']}" id="c_id">
	    <div class="panel admin-panel">
	       <div class="padding border-bottom" style="overflow: hidden;">
				<a class="button button-small border-green" href="{:U('ArticleComm/article_comm_add')}">添加学校交流</a>
			</div>
	        <table class="table table-hover">
	        	<tr><th>ID</th><th>标题</th><th>分类<th>时间</th><th>排序</th><th>操作</th></tr>
	        	<volist name="list" id="a">
	        	<tr>
		        	<td>{$a.id}</td>
		        	<td>
		        	{$a.title}
		        	</td>
		        	<td>{$ac_list[$a['ac_id']].name}</td>
		        	<td>
					{$a['time']|date='Y-m-d H:i:s',###}
					</td>
					<td>{$a.sort}</td>
		        	<td>
		        	<a class="button border-blue button-little" href="{:U('ArticleComm/article_comm_update',array('p'=>$_GET['p'],'c_id'=>$_GET['c_id'],'search_word'=>$_GET['search_word']))}?id={$a.id}">修改</a>
		        	<a class="button border-blue button-little" href="{:U('ArticleComm/comment_list')}?id={$a.id}">查看评论</a>
					<a class="button border-yellow button-little" onclick="{if(confirm('确认删除?')){return true;}return false;}" href="{:U('ArticleComm/article_comm_delete')}?id={$a.id}">删除</a>
		        	</td>
	        	</tr>
	        	</volist>
	        </table>
	    </div>
	    <div class="meneame" style="margin-bottom: 20px;">{$page}</div>
	    </form>
	    </div>
	    </div>
		<!--底部-->

		
		<import type='js' file="admin.pintuer4.js.jquery" />
		<import type='js' file="admin.pintuer4.js.pintuer" />
		<import type='js' file="admin.pintuer4.js.respond" />
		<import type='js' file="admin.pintuer4.js.layer" />
		<import type='js' file="admin.pintuer4.js.admin" />
		<script>
			$(function() {
				
				//大于移动端800宽度才弹出提示
				if ($(window).width() >= 800) {
					layer.open({
						type: 1,
						shade: false,
						title: false, //不显示标题
						area: ['420px', '640px'],
						content: $('#alert-talk'), //捕获的元素
						cancel: function(index) {
							layer.close(index);
						}
					});
				}
				$('#search').click(function(){
					url = window.location.pathname +  '?search_word=' + $('#search_word').val()+'&c_id='+$('#c_id').val();
					location.href = url;
				});

				$('#search_word').bind('keypress',function(event){
			        if(event.keyCode == "13")    
			        {
			        	url = window.location.pathname +  '?search_word=' + $('#search_word').val()+'&c_id='+$('#c_id').val();
			    		location.href = url;
			        }
			    });
			});
		</script>
	</body>

</html>
